package com.caac.core.web.view;

import com.caac.core.dm.SysLog;
import com.caac.core.util.DateUtils;
import com.caac.core.web.util.LabelLinkBean;

/**
 * <p>Title: </p>
 * <p>Description: </p>
 * <p>Copyright: Copyright caac 2005</p>
 * <p>Company: caac</p>
 * @author <a href="mailto:project@caac.com.cn">Project Group</a>
 * @version 1.0
 */

public class SysLogView extends BaseView {
    private SysLog sysLog;

    public void setSysLog(SysLog sysLog) {
        this.sysLog = sysLog;
    }

    public SysLog getSysLog() {
        return sysLog;
    }

    public String getOperateTime() {
        return DateUtils.convertToString(DateUtils.PATTERN_DATETIME,
                                         sysLog.getOperateTime());
    }

    public LabelLinkBean getUsername() {
        return new LabelLinkBean(sysLog.getUsername(),
                                 "/protected/usermanage/viewUser.do?username=" +
                                 sysLog.getUsername());
    }
}
